Home
last modified time | relevance | path

Searched +full:js +full:- +full:tokens (Results 1 – 25 of 1005) sorted by relevance

12345678910>>...41

/aosp_15_r20/external/jsmn/
H A Djsmn.h61 /* Not enough tokens were provided */
62 JSMN_ERROR_NOMEM = -1,
64 JSMN_ERROR_INVAL = -2,
66 JSMN_ERROR_PART = -3
96 * Create JSON parser over an array of tokens
101 * Run JSON parser. It parses a JSON data string into and array of tokens, each
105 JSMN_API int jsmn_parse(jsmn_parser *parser, const char *js, const size_t len,
106 jsmntok_t *tokens, const unsigned int num_tokens);
112 static jsmntok_t *jsmn_alloc_token(jsmn_parser *parser, jsmntok_t *tokens, in jsmn_alloc_token() argument
115 if (parser->toknext >= num_tokens) { in jsmn_alloc_token()
[all …]
H A DREADME.md4 [![Build Status](https://travis-ci.org/zserge/jsmn.svg?branch=master)](https://travis-ci.org/zserge…
7 easily integrated into resource-limited or embedded projects.
17 ----------
28 dependencies or non-standard C extensions). And of course, **simplicity** is a
29 key feature - simple code style, simple algorithm, simple integration into
33 --------
42 * incremental single-pass parsing
43 * library code is covered with unit-tests
46 ------
52 It holds the following tokens:
[all …]
/aosp_15_r20/external/jsmn/test/
H A Dtests.c22 check(parse("{\"a\":{},\"b\":{}}", 5, 5, JSMN_OBJECT, -1, -1, 2, JSMN_STRING, in test_object()
23 "a", 1, JSMN_OBJECT, -1, -1, 0, JSMN_STRING, "b", 1, JSMN_OBJECT, in test_object()
24 -1, -1, 0)); in test_object()
26 JSMN_OBJECT, -1, -1, 3, JSMN_STRING, "Day", 1, JSMN_PRIMITIVE, in test_object()
29 check(parse("{\"a\": 0, \"b\": \"c\"}", 5, 5, JSMN_OBJECT, -1, -1, 2, in test_object()
54 check(parse("[10]", 2, 2, JSMN_ARRAY, -1, -1, 1, JSMN_PRIMITIVE, "10")); in test_array()
62 check(parse("{\"boolVar\" : true }", 3, 3, JSMN_OBJECT, -1, -1, 1, in test_primitive()
64 check(parse("{\"boolVar\" : false }", 3, 3, JSMN_OBJECT, -1, -1, 1, in test_primitive()
66 check(parse("{\"nullVar\" : null }", 3, 3, JSMN_OBJECT, -1, -1, 1, in test_primitive()
68 check(parse("{\"intVar\" : 12}", 3, 3, JSMN_OBJECT, -1, -1, 1, JSMN_STRING, in test_primitive()
[all …]
/aosp_15_r20/external/antlr/runtime/JavaScript/tests/functional/
H A Dt048rewrite.html1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xht…
4 <meta http-equiv="content-type" content="text/html;charset=utf-8" />
7 <!-- ANTLR includes -->
8 <script type="text/javascript" src="../../lib/antlr3-all.js"></script>
9 <script type="text/javascript" src="t048rewrite.js"></script>
11 <!-- JsUnit include -->
12 <script type="text/javascript" src="../jsunit/app/jsUnitCore.js"></script>
14 <!-- Test Code -->
35 var tokens = _parse("abc");
36 tokens.insertBefore(0,"0");
[all …]
H A Drhino-python.prog15 * out how to create a Java char array from JS. . .
25 eval(loadFile("../../lib/antlr3-all.js"));
26 eval(loadFile("../../lib/antlr3-cli.js"));
27 eval(loadFile("PythonLexer.js"));
28 eval(loadFile("PythonParser.js"));
29 eval(loadFile("rhino-python.extensions"));
58 var tokens = new ANTLR.runtime.CommonTokenStream(lexer);
59 tokens.discardOffChannelTokens=true;
60 var indentedSource = new PythonTokenSource(tokens);
61 tokens = new ANTLR.runtime.CommonTokenStream(indentedSource);
[all …]
H A Dt020fuzzy.html1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xht…
4 <meta http-equiv="content-type" content="text/html;charset=utf-8" />
7 <!-- ANTLR includes -->
8 <script type="text/javascript" src="../../lib/antlr3-all.js"></script>
9 <script type="text/javascript" src="t020fuzzy.js"></script>
11 <!-- JsUnit include -->
12 <script type="text/javascript" src="../jsunit/app/jsUnitCore.js"></script>
14 <!-- Test Code -->
25 " TokenStream tokens = new CommonTokenStream(lex);",
26 " tokens.toString();",
[all …]
H A Dt057autoAST.html1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xht…
4 <meta http-equiv="content-type" content="text/html;charset=utf-8" />
7 <!-- ANTLR includes -->
8 <script type="text/javascript" src="../../lib/antlr3-all.js"></script>
10 <script type="text/javascript" src="t057autoAST1Lexer.js"></script>
11 <script type="text/javascript" src="t057autoAST1Parser.js"></script>
12 <script type="text/javascript" src="t057autoAST2Lexer.js"></script>
13 <script type="text/javascript" src="t057autoAST2Parser.js"></script>
14 <script type="text/javascript" src="t057autoAST3Lexer.js"></script>
15 <script type="text/javascript" src="t057autoAST3Parser.js"></script>
[all …]
H A Dt019lexer.html1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xht…
4 <meta http-equiv="content-type" content="text/html;charset=utf-8" />
7 <!-- ANTLR includes -->
8 <script type="text/javascript" src="../../lib/antlr3-all.js"></script>
9 <script type="text/javascript" src="t019lexer.js"></script>
11 <!-- JsUnit include -->
12 <script type="text/javascript" src="../jsunit/app/jsUnitCore.js"></script>
14 <!-- Test Code -->
25 " TokenStream tokens = new CommonTokenStream(lex);",
26 " tokens.toString();",
[all …]
/aosp_15_r20/prebuilts/go/linux-x86/src/html/template/
Djs.go2 // Use of this source code is governed by a BSD-style
16 // jsWhitespace contains all of the JS whitespace characters, as defined
18 // See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions/Character_…
22 // given run of tokens starts a regular expression instead of a division
25 // This assumes that the token run does not include any string tokens, comment
26 // tokens, regular expression literal tokens, or division operators.
32 // https://www.mozilla.org/js/language/js20-2000-07/rationale/syntax.html
34 // Trim all JS whitespace characters
40 // All cases below are in the single-byte UTF-8 group.
41 switch c, n := s[len(s)-1], len(s); c {
[all …]
Djs_test.go2 // Use of this source code is governed by a BSD-style
44 // Whether the + or - is infix or prefix, it cannot precede a
47 {jsCtxRegexp, "-"},
50 // pre-increment operator, but in practice devs do not try to
54 {jsCtxDivOp, "--"},
56 {jsCtxDivOp, "x--"},
59 {jsCtxRegexp, "x---"}, // A postfix -- then a -.
84 // Some JS interpreters treat NBSP as a normal space, so
99 t.Error("Blank tokens")
103 t.Error("Blank tokens")
[all …]
Dtransition.go2 // Use of this source code is governed by a BSD-style
47 var commentStart = []byte("<!--")
48 var commentEnd = []byte("-->")
193 if i := bytes.Index(s, commentEnd); i != -1 {
200 // case-insensitively signals the end of the special tag body.
222 if i := indexTagEnd(s, specialTagEndMarkers[c.element]); i != -1 {
229 // indexTagEnd finds the index of a special tag end in a case insensitive way, or returns -1
236 if i == -1 {
244 if len(s) > 0 && bytes.IndexByte(tagEndSeparators, s[0]) != -1 {
251 return -1
[all …]
/aosp_15_r20/external/flatbuffers/
H A Dyarn.lock5 "@babel/code-[email protected]":
7 …resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.11.tgz#f4ad435aa263db93…
8 …integrity sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETGOiOH…
12 "@babel/helper-validator-identifier@^7.16.7":
14 …solved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identif…
15 …integrity sha512-hsEnFemeiW4D08A5gUAZxLBTXpZ39P+a+DGDsHw1yxqyQ/jzFEnxf5uTEGp+3bzAbNOxU1paTgYS4ECU/…
19 …resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.16.10.tgz#744f2eb81579d6eea7…
20 …integrity sha512-5FnTQLSLswEj6IkgVw5KusNUUFY9ZGqe/TRFnP/BKYHYgfh7tc+C7mwiy95/yNP7Dh9x580Vv8r7u7ZfT…
22 "@babel/helper-validator-identifier" "^7.16.7"
24 js-tokens "^4.0.0"
[all …]
/aosp_15_r20/external/libchrome/base/process/
H A Dprocess_metrics_linux.cc2 // Use of this source code is governed by a BSD-style license that can be
101 // This can be reached if the process dies when proc is read -- in that case, in ReadProcStatusAndGetFieldAsSizeT()
134 // on success or -1 on error.
140 return -1; in GetProcessCPU()
152 // bind mount into /sys/kernel/debug and synchronously reading the in-memory
161 meminfo->gem_objects = -1; in ReadChromeOSGraphicsMemory()
162 meminfo->gem_size = -1; in ReadChromeOSGraphicsMemory()
164 int gem_objects = -1; in ReadChromeOSGraphicsMemory()
165 long long gem_size = -1; in ReadChromeOSGraphicsMemory()
169 meminfo->gem_objects = gem_objects; in ReadChromeOSGraphicsMemory()
[all …]
/aosp_15_r20/external/cronet/base/process/
H A Dprocess_metrics_linux.cc2 // Use of this source code is governed by a BSD-style license that can be
41 #include "third_party/abseil-cpp/absl/strings/ascii.h"
71 if (utime.value_or(-1) < 0) { in ParseTotalCPUTimeFromStats()
77 if (stime.value_or(-1) < 0) { in ParseTotalCPUTimeFromStats()
153 counts->minor = in GetPageFaultCounts()
155 counts->major = in GetPageFaultCounts()
168 return -1; in GetOpenFdCount()
186 return -1; in GetOpenFdSoftLimit()
193 auto tokens = in GetOpenFdSoftLimit() local
195 if (tokens.size() > 3) { in GetOpenFdSoftLimit()
[all …]
/aosp_15_r20/external/skia/modules/canvaskit/npm_build/
H A Dpackage-lock.json2 "name": "canvaskit-wasm",
8 "name": "canvaskit-wasm",
10 "license": "BSD-3-Clause",
12 "@definitelytyped/header-parser": "0.0.121",
18 "node_modules/@definitelytyped/header-parser": {
20 …"resolved": "https://registry.npmjs.org/@definitelytyped/header-parser/-/header-parser-0.0.121.tgz…
21 …"integrity": "sha512-78HY1J+QiwZPXFZQWb9gPQPxAMNg6/1e4gl7gL/8dmd17vVWLi3AGrLJoG8Pn1p8d7MF2rlPw/2AE…
24 "@definitelytyped/typescript-versions": "^0.0.121",
29 "node_modules/@definitelytyped/typescript-versions": {
31 …ed": "https://registry.npmjs.org/@definitelytyped/typescript-versions/-/typescript-versions-0.0.12…
[all …]
/aosp_15_r20/external/skia/experimental/tskit/
H A Dpackage-lock.json9 "license": "BSD-3-Clause",
11 "@typescript-eslint/eslint-plugin": "^4.21.0",
12 "@typescript-eslint/parser": "^4.21.0",
14 "eslint-config-airbnb-typescript": "^12.3.1",
15 "eslint-plugin-import": "^2.22.1",
19 "node_modules/@babel/code-frame": {
21 "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.12.11.tgz",
22 …"integrity": "sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETG…
28 "node_modules/@babel/helper-validator-identifier": {
30 …solved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identif…
[all …]
/aosp_15_r20/external/libchrome/mojo/public/tools/bindings/
H A Dmojom_bindings_generator.py3 # Use of this source code is governed by a BSD-style license that can be
33 # Manually check for the command-line flag. (This isn't quite right, since it
34 # ignores, e.g., "--", but it's close enough.)
35 if "--use_bundled_pylibs" in sys.argv[1:]:
74 """Make a (human-readable) message listing a chain of imports. (Returned
94 RelativePath with first file found, or an arbitrary non-existent file
116 # to be very strong, cryptographically. It just needs to be non-trivial
122 # Take the first 4 bytes as a little-endian uint32.
154 # Support some very simple single-line comments in typemap JSON.
168 # Return the already-generated module.
[all …]
/aosp_15_r20/external/jsmn/example/
H A Djsondump.c9 * with one difference - it frees old memory pointer in case of realloc
12 * memory can't be re-allocated - use standard realloc() instead.
28 static int dump(const char *js, jsmntok_t *t, size_t count, int indent) { in dump() argument
34 if (t->type == JSMN_PRIMITIVE) { in dump()
35 printf("%.*s", t->end - t->start, js + t->start); in dump()
37 } else if (t->type == JSMN_STRING) { in dump()
38 printf("'%.*s'", t->end - t->start, js + t->start); in dump()
40 } else if (t->type == JSMN_OBJECT) { in dump()
43 for (i = 0; i < t->size; i++) { in dump()
48 j += dump(js, key, count - j, indent + 1); in dump()
[all …]
/aosp_15_r20/external/jacoco/org.jacoco.report/src/org/jacoco/report/internal/html/resources/
H A Dprettify.js7 // http://www.apache.org/licenses/LICENSE-2.0
18 * some functions for browser-side pretty printing of code contained in html.
22 * <a href="http://google-code-prettify.googlecode.com/svn/trunk/README.html#langs">README</a>
27 * Smalltalk, Lisp-like, or CAML-like languages without an explicit lang class.
31 * {@code <script type="text/javascript" src="/path/to/prettify.js"></script>}
42 * language, as in {@code <pre class="prettyprint lang-java">}. Any class that
43 * starts with "lang-" followed by a file extension, specifies the file type.
44 * See the "lang-*.js" files in this directory for code that implements
45 * per-language file handlers.
177 /** A set of tokens that can precede a regular expression literal in
[all …]
/aosp_15_r20/packages/modules/AdServices/adservices/service-core/java/com/android/adservices/service/adselection/
DAdSelectionScriptEngine.java8 * http://www.apache.org/licenses/LICENSE-2.0
19 import static com.android.adservices.service.js.JSScriptArgument.arrayArg;
20 import static com.android.adservices.service.js.JSScriptArgument.jsonArg;
21 import static com.android.adservices.service.js.JSScriptArgument.recordArg;
22 import static com.android.adservices.service.js.JSScriptArgument.stringArg;
23 import static com.android.adservices.service.js.JSScriptArgument.stringArrayArg;
24 import static com.android.adservices.service.js.JSScriptEngineCommonConstants.ENTRY_POINT_FUNC_NAME;
25 import static com.android.adservices.service.js.JSScriptEngineCommonConstants.JS_EXECUTION_RESULT_I…
26 import static com.android.adservices.service.js.JSScriptEngineCommonConstants.JS_EXECUTION_STATUS_U…
27 import static com.android.adservices.service.js.JSScriptEngineCommonConstants.JS_SCRIPT_STATUS_SUCC…
[all …]
/aosp_15_r20/external/skia/modules/pathkit/
H A Dpackage-lock.json2 "name": "pathkit-local",
7 "@babel/code-frame": {
9 "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz",
10 …"integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3O…
18 "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.12.10.tgz",
19 …"integrity": "sha512-eTAlQKq65zHfkHZV0sIVODCPGVgoo1HdBlbSLi9CqOzuZanMv2ihzY+4paiKr1mH+XmYESMAmJ/dp…
22 "@babel/code-frame": "^7.10.4",
24 "@babel/helper-module-transforms": "^7.12.1",
30 "convert-source-map": "^1.7.0",
32 "gensync": "^1.0.0-beta.1",
[all …]
/aosp_15_r20/external/skia/modules/canvaskit/
H A Dpackage-lock.json2 "name": "canvaskit-local",
8 "name": "canvaskit-local",
10 "license": "BSD-3-Clause",
12 "is-docker": "~1.1.0",
13 "jasmine-core": "~3.6.0",
15 "karma-chrome-launcher": "~3.1.0",
16 "karma-coverage": "~2.0.3",
17 "karma-jasmine": "~4.0.1",
21 "node_modules/@babel/code-frame": {
23 "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz",
[all …]
/aosp_15_r20/external/chromium-trace/catapult/common/py_vulcanize/py_vulcanize/
H A Dgenerate.py2 # Use of this source code is governed by a BSD-style license that can be
26 <!--
30 -->
35 // Use of this source code is governed by a BSD-style license that can be
46 * Use of this source code is governed by a BSD-style license that can be
49 /* WARNING: This file is auto-generated.
60 # This is for chromium-build-stats.appspot.com (ukai@)
63 # This is for chromium-build-stats-staging.appspot.com (ukai@)
67 # Add more tokens here if traces are served from other domains.
75 assert f.encoding == 'utf-8'
[all …]
/aosp_15_r20/external/antlr/runtime/JavaScript/src/org/antlr/runtime/
H A DTokenRewriteStream.js5 * operations are done lazily--only if you convert the buffer to a
7 * all the time. As the buffer of tokens is converted to strings, the
13 * Since the operations are done lazily at toString-time, operations do not
15 * index i does not change the index values for tokens i+1..n-1.
25 * TokenRewriteStream tokens = new TokenRewriteStream(lex);
26 * T parser = new T(tokens);
34 * System.out.println(tokens.toString());
41 * useful for generating a C file and also its header file--all from the
44 * tokens.insertAfter("pass1", t, "text to put after t");}
45 * tokens.insertAfter("pass2", u, "text after u");}
[all …]
/aosp_15_r20/dalvik/docs/
H A Dprettify.js7 // http://www.apache.org/licenses/LICENSE-2.0
18 * some functions for browser-side pretty printing of code contained in html.
23 * because of commenting conventions, doesn't work on Smalltalk, Lisp-like, or
24 * CAML-like languages.
27 * know whether it works. If it has a C-like, Bash-like, or XML-like syntax
32 * <script type="text/javascript" src="/path/to/prettify.js"></script>
93 /** Splits input on space and returns an Object mapping each non-empty part to
99 for (var i = words.length; --i >= 0;) {
202 /** A set of tokens that can precede a regular expression literal in
204 * http://www.mozilla.org/js/language/js20/rationale/syntax.html has the full
[all …]

12345678910>>...41