MCPcopy
hub / github.com/jquerytools/jquerytools / it

Function it

lib/jslint.js:26–29  ·  view source on GitHub ↗
(type,value)

Source from the content-addressed store, hash-verified

24character=0;s=lines[line].replace(/\t/g,tab);at=s.search(cx);if(at>=0){warningAt("Unsafe character.",line,at);}
25return true;}
26function it(type,value){var i,t;if(type==='(punctuator)'||(type==='(identifier)'&&syntax.hasOwnProperty(value))){t=syntax[value];if(!t.id){t=syntax[type];}}else{t=syntax[type];}
27t=Object.beget(t);if(type==='(string)'){if(jx.test(value)){warningAt("Script URL.",line,from);}}else if(type==='(identifier)'){if(option.nomen&&value.charAt(0)==='_'){warningAt("Unexpected '_' in '{a}'.",line,from,value);}}
28t.value=value;t.line=line;t.character=character;t.from=from;i=t.id;if(i!=='(endline)'){prereg=i&&(('(,=:[!&|?{};'.indexOf(i.charAt(i.length-1))>=0)||i==='return');}
29return t;}
30return{init:function(source){if(typeof source==='string'){lines=source.replace(/\r\n/g,'\n').replace(/\r/g,'\n').split('\n');}else{lines=source;}
31line=-1;nextLine();from=0;},token:function(){var b,c,captures,d,depth,high,i,l,low,q,t;function match(x){var r=x.exec(s),r1;if(r){l=r[0].length;r1=r[1];c=r1.charAt(0);s=s.substr(l);character+=l;from=character-r1.length;return r1;}}
32function string(x){var c,j,r='';if(jsonmode&&x!=='"'){warningAt("Strings must use doublequote.",line,character);}

Callers 2

stringFunction · 0.85
jslint.jsFile · 0.85

Calls 1

warningAtFunction · 0.85

Tested by

no test coverage detected