MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / fxParseJSONValue

Function fxParseJSONValue

modules/piu/PC/Code/piuCodeJSON.c:293–314  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

291}
292
293void fxParseJSONValue(PiuCodeParser parser)
294{
295 switch (parser->token) {
296 case XS_JSON_TOKEN_FALSE:
297 case XS_JSON_TOKEN_TRUE:
298 case XS_JSON_TOKEN_NULL:
299 case XS_JSON_TOKEN_NUMBER:
300 case XS_JSON_TOKEN_STRING:
301 PiuCodeParserColorAt(parser, 2, parser->offset);
302 PiuCodeParserColorAt(parser, 0, parser->input);
303 fxParseJSONToken(parser);
304 break;
305 case XS_JSON_TOKEN_LEFT_BRACE:
306 fxParseJSONObject(parser);
307 break;
308 case XS_JSON_TOKEN_LEFT_BRACKET:
309 fxParseJSONArray(parser);
310 break;
311 default:
312 return;
313 }
314}

Callers 3

PiuCodeFormatJSONFunction · 0.70
fxParseJSONArrayFunction · 0.70
fxParseJSONObjectFunction · 0.70

Calls 4

PiuCodeParserColorAtFunction · 0.85
fxParseJSONTokenFunction · 0.70
fxParseJSONObjectFunction · 0.70
fxParseJSONArrayFunction · 0.70

Tested by

no test coverage detected