MCPcopy
hub / github.com/jquerytools/jquerytools / jsonArray

Function jsonArray

lib/jslint.js:345–348  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

343advance(',');}}
344advance('}');}
345function jsonArray(){var t=nexttoken;advance('[');if(nexttoken.id!==']'){for(;;){if(nexttoken.id==='(end)'){error("Missing ']' to match '[' from line {a}.",nexttoken,t.line+1);}else if(nexttoken.id===']'){warning("Unexpected comma.",token);break;}else if(nexttoken.id===','){error("Unexpected comma.",nexttoken);}
346jsonValue();if(nexttoken.id!==','){break;}
347advance(',');}}
348advance(']');}
349switch(nexttoken.id){case'{':jsonObject();break;case'[':jsonArray();break;case'true':case'false':case'null':case'(number)':case'(string)':advance();break;case'-':advance('-');if(token.character!==nexttoken.from){warning("Unexpected space after '-'.",token);}
350adjacent(token,nexttoken);advance('(number)');break;default:error("Expected a JSON value.",nexttoken);}}
351var itself=function(s,o){var a,i;JSLINT.errors=[];predefined=Object.beget(standard);if(o){a=o.predef;if(a instanceof Array){for(i=0;i<a.length;i+=1){predefined[a[i]]=true;}}

Callers 1

jsonValueFunction · 0.85

Calls 4

advanceFunction · 0.85
errorFunction · 0.85
warningFunction · 0.85
jsonValueFunction · 0.85

Tested by

no test coverage detected