MCPcopy Create free account
hub / github.com/dchester/jsonpath / filterTokenLocation

Function filterTokenLocation

jsonpath.js:3563–3582  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3561 }
3562
3563 function filterTokenLocation() {
3564 var i, entry, token, tokens = [];
3565
3566 for (i = 0; i < extra.tokens.length; ++i) {
3567 entry = extra.tokens[i];
3568 token = {
3569 type: entry.type,
3570 value: entry.value
3571 };
3572 if (extra.range) {
3573 token.range = entry.range;
3574 }
3575 if (extra.loc) {
3576 token.loc = entry.loc;
3577 }
3578 tokens.push(token);
3579 }
3580
3581 extra.tokens = tokens;
3582 }
3583
3584 function tokenize(code, options) {
3585 var toString,

Callers 2

tokenizeFunction · 0.85
parseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected