code: function(ast, offset) {
  			var found = null;
  			var dom = ast;
  			var missingTagClose = false;
  			if (!Array.isArray(ast) && ast.children){
  				dom = ast.children;
  			}
  			 Visitor.visit(dom, {
  	            visitNode: function(node) {
  					if(node.range[0] <= offset) {
  						found = node;
  					} else {
  					    return Visitor.BREAK;
  					}      
  	            },
  	            endVisitNode: function(node) {
  	            	if(found && !missingTagClose && offset >= found.range[1] && offset > node.range[0]) {
  	            		found = node;
  	            		// If at the boundary of a tag range and there is a missing end tag, return the innermost tag  <a><b></a>
  	            		if (offset === found.range[1] && found.endrange && found.openrange && found.endrange[1] === found.openrange[1]){
  	            			missingTagClose = true;
  	            		}
  	            	}
  	            }
  	        });
  	        return found;
  		}
docs: $NON-NLS-0$ 
  Returns the ast node at the given offset or the parent node enclosing it
  @param {Object} ast The AST to inspect
  @param {Number} offset The offset into the source
  @returns {Object} The AST node at the given offset or null
  @since 10.0