Home
last modified time | relevance | path

Searched refs:parser (Results 1 – 25 of 27) sorted by relevance

12

/optee_benchmark/libyaml/src/
A Dscanner.c766 *token = DEQUEUE(parser, parser->tokens); in yaml_parser_scan()
789 parser->problem_mark = parser->mark; in yaml_parser_set_scanner_error()
1118 parser->tokens_parsed + (parser->tokens.tail - parser->tokens.head); in yaml_parser_save_simple_key()
1224 if (!PUSH(parser, parser->indents, parser->indent)) in yaml_parser_roll_indent()
1282 parser->indent = POP(parser, parser->indents); in yaml_parser_unroll_indent()
1318 parser->mark, parser->mark); in yaml_parser_fetch_stream_start()
1320 if (!ENQUEUE(parser, parser->tokens, token)) in yaml_parser_fetch_stream_start()
1358 if (!ENQUEUE(parser, parser->tokens, token)) in yaml_parser_fetch_stream_end()
1439 if (!ENQUEUE(parser, parser->tokens, token)) in yaml_parser_fetch_document_indicator()
1482 if (!ENQUEUE(parser, parser->tokens, token)) in yaml_parser_fetch_flow_collection_start()
[all …]
A Dreader.c64 if (parser->raw_buffer.last - parser->raw_buffer.pointer >= 2 in yaml_parser_determine_encoding()
100 if (parser->raw_buffer.start == parser->raw_buffer.pointer in yaml_parser_update_raw_buffer()
110 if (parser->raw_buffer.start < parser->raw_buffer.pointer in yaml_parser_update_raw_buffer()
117 parser->raw_buffer.pointer = parser->raw_buffer.start; in yaml_parser_update_raw_buffer()
121 if (!parser->read_handler(parser->read_handler_data, parser->raw_buffer.last, in yaml_parser_update_raw_buffer()
150 if (parser->eof && parser->raw_buffer.pointer == parser->raw_buffer.last) in yaml_parser_update_buffer()
167 if (parser->buffer.start < parser->buffer.pointer in yaml_parser_update_buffer()
171 parser->buffer.pointer = parser->buffer.start; in yaml_parser_update_buffer()
172 parser->buffer.last = parser->buffer.start + size; in yaml_parser_update_buffer()
175 parser->buffer.pointer = parser->buffer.start; in yaml_parser_update_buffer()
[all …]
A Dparser.c452 parser->state = POP(parser, parser->states); in yaml_parser_parse_document_content()
545 parser->state = POP(parser, parser->states); in yaml_parser_parse_node()
651 parser->state = POP(parser, parser->states); in yaml_parser_parse_node()
694 parser->state = POP(parser, parser->states); in yaml_parser_parse_node()
763 parser->state = POP(parser, parser->states); in yaml_parser_parse_block_sequence_entry()
816 parser->state = POP(parser, parser->states); in yaml_parser_parse_indentless_sequence_entry()
873 parser->state = POP(parser, parser->states); in yaml_parser_parse_block_mapping_key()
999 parser->state = POP(parser, parser->states); in yaml_parser_parse_flow_sequence_entry()
1000 dummy_mark = POP(parser, parser->marks); in yaml_parser_parse_flow_sequence_entry()
1023 if (!PUSH(parser, parser->states, in yaml_parser_parse_flow_sequence_entry_mapping_key()
[all …]
A Dloader.c93 if (!STACK_INIT(parser, parser->aliases, INITIAL_STACK_SIZE)) in yaml_parser_load()
154 while (!STACK_EMPTY(parser, parser->aliases)) { in yaml_parser_delete_aliases()
155 yaml_free(POP(parser, parser->aliases).anchor); in yaml_parser_delete_aliases()
157 STACK_DEL(parser, parser->aliases); in yaml_parser_delete_aliases()
247 if (!PUSH(parser, parser->aliases, data)) { in yaml_parser_register_anchor()
301 if (!PUSH(parser, parser->document->nodes, node)) goto error; in yaml_parser_load_scalar()
303 index = parser->document->nodes.top - parser->document->nodes.start; in yaml_parser_load_scalar()
348 if (!PUSH(parser, parser->document->nodes, node)) goto error; in yaml_parser_load_sequence()
350 index = parser->document->nodes.top - parser->document->nodes.start; in yaml_parser_load_sequence()
411 if (!PUSH(parser, parser->document->nodes, node)) goto error; in yaml_parser_load_mapping()
[all …]
A Dapi.c198 BUFFER_DEL(parser, parser->buffer); in yaml_parser_initialize()
199 QUEUE_DEL(parser, parser->tokens); in yaml_parser_initialize()
200 STACK_DEL(parser, parser->indents); in yaml_parser_initialize()
202 STACK_DEL(parser, parser->states); in yaml_parser_initialize()
203 STACK_DEL(parser, parser->marks); in yaml_parser_initialize()
219 BUFFER_DEL(parser, parser->buffer); in yaml_parser_delete()
223 QUEUE_DEL(parser, parser->tokens); in yaml_parser_delete()
224 STACK_DEL(parser, parser->indents); in yaml_parser_delete()
226 STACK_DEL(parser, parser->states); in yaml_parser_delete()
227 STACK_DEL(parser, parser->marks); in yaml_parser_delete()
[all …]
A DMakefile.am3 libyaml_la_SOURCES = yaml_private.h api.c reader.c scanner.c parser.c loader.c writer.c emitter.c d…
/optee_benchmark/libyaml/tests/
A Dtest-reader.c119 yaml_parser_t parser; in check_utf8_sequences() local
148 parser.problem, parser.problem_value, parser.problem_offset); in check_utf8_sequences()
152 parser.problem, parser.problem_offset); in check_utf8_sequences()
167 yaml_parser_t parser; in check_boms() local
209 yaml_parser_t parser; in check_long_utf8() local
253 if (parser.buffer.pointer[0] != ch0 || parser.buffer.pointer[1] != ch1) { in check_long_utf8()
255 (int)parser.buffer.pointer[0], (int)parser.buffer.pointer[1], in check_long_utf8()
269 …texpected NUL, found %X (eof=%d, unread=%zu)\n", (int)parser.buffer.pointer[0], parser.eof, parser in check_long_utf8()
281 yaml_parser_t parser; in check_long_utf16() local
324 if (parser.buffer.pointer[0] != ch0 || parser.buffer.pointer[1] != ch1) { in check_long_utf16()
[all …]
A Dexample-reformatter-alt.c16 yaml_parser_t parser; in main() local
22 memset(&parser, 0, sizeof(parser)); in main()
115 switch (parser.error) in main()
124 parser.problem_value, parser.problem_offset); in main()
136 parser.context_mark.line+1, parser.context_mark.column+1, in main()
137 parser.problem, parser.problem_mark.line+1, in main()
142 parser.problem, parser.problem_mark.line+1, in main()
152 parser.problem, parser.problem_mark.line+1, in main()
157 parser.problem, parser.problem_mark.line+1, in main()
167 parser.problem, parser.problem_mark.line+1, in main()
[all …]
A Dexample-reformatter.c16 yaml_parser_t parser; in main() local
22 memset(&parser, 0, sizeof(parser)); in main()
106 yaml_parser_delete(&parser); in main()
115 switch (parser.error) in main()
124 parser.problem_value, parser.problem_offset); in main()
136 parser.context_mark.line+1, parser.context_mark.column+1, in main()
137 parser.problem, parser.problem_mark.line+1, in main()
142 parser.problem, parser.problem_mark.line+1, in main()
151 parser.context_mark.line+1, parser.context_mark.column+1, in main()
152 parser.problem, parser.problem_mark.line+1, in main()
[all …]
A Dexample-deconstructor-alt.c16 yaml_parser_t parser; in main() local
25 memset(&parser, 0, sizeof(parser)); in main()
78 yaml_parser_delete(&parser); in main()
698 switch (parser.error) in main()
707 parser.problem_value, parser.problem_offset); in main()
719 parser.context_mark.line+1, parser.context_mark.column+1, in main()
720 parser.problem, parser.problem_mark.line+1, in main()
725 parser.problem, parser.problem_mark.line+1, in main()
734 parser.context_mark.line+1, parser.context_mark.column+1, in main()
735 parser.problem, parser.problem_mark.line+1, in main()
[all …]
A Dexample-deconstructor.c16 yaml_parser_t parser; in main() local
23 memset(&parser, 0, sizeof(parser)); in main()
76 yaml_parser_delete(&parser); in main()
1028 switch (parser.error) in main()
1037 parser.problem_value, parser.problem_offset); in main()
1049 parser.context_mark.line+1, parser.context_mark.column+1, in main()
1050 parser.problem, parser.problem_mark.line+1, in main()
1055 parser.problem, parser.problem_mark.line+1, in main()
1064 parser.context_mark.line+1, parser.context_mark.column+1, in main()
1065 parser.problem, parser.problem_mark.line+1, in main()
[all …]
A Drun-loader.c24 yaml_parser_t parser; in main() local
36 assert(yaml_parser_initialize(&parser)); in main()
38 yaml_parser_set_input_file(&parser, file); in main()
42 if (!yaml_parser_load(&parser, &document)) { in main()
54 yaml_parser_delete(&parser); in main()
A Drun-parser.c24 yaml_parser_t parser; in main() local
36 assert(yaml_parser_initialize(&parser)); in main()
38 yaml_parser_set_input_file(&parser, file); in main()
42 if (!yaml_parser_parse(&parser, &event)) { in main()
54 yaml_parser_delete(&parser); in main()
A Drun-scanner.c24 yaml_parser_t parser; in main() local
36 assert(yaml_parser_initialize(&parser)); in main()
38 yaml_parser_set_input_file(&parser, file); in main()
42 if (!yaml_parser_scan(&parser, &token)) { in main()
54 yaml_parser_delete(&parser); in main()
A Drun-dumper.c226 yaml_parser_t parser; in main() local
247 assert(yaml_parser_initialize(&parser)); in main()
248 yaml_parser_set_input_file(&parser, file); in main()
261 if (!yaml_parser_load(&parser, &document)) { in main()
279 yaml_parser_delete(&parser); in main()
287 assert(yaml_parser_initialize(&parser)); in main()
288 yaml_parser_set_input_string(&parser, buffer, written); in main()
292 …assert(yaml_parser_load(&parser, &document) || print_output(argv[number], buffer, written, count)); in main()
300 yaml_parser_delete(&parser); in main()
A Drun-emitter.c251 yaml_parser_t parser; in main() local
271 assert(yaml_parser_initialize(&parser)); in main()
272 yaml_parser_set_input_file(&parser, file); in main()
284 if (!yaml_parser_parse(&parser, &event)) { in main()
297 yaml_parser_delete(&parser); in main()
304 assert(yaml_parser_initialize(&parser)); in main()
305 yaml_parser_set_input_string(&parser, buffer, written); in main()
309 … assert(yaml_parser_parse(&parser, &event) || print_output(argv[number], buffer, written, count)); in main()
315 yaml_parser_delete(&parser); in main()
/optee_benchmark/libyaml/tests/run-test-suite/src/
A DReadMe.md1 libyaml-parser-emitter
17 ./libyaml-parser file.yaml
18 ./libyaml-parser < file.yaml
19 cat file.yaml | ./libyaml-parser
22 Print the YAML for a libyaml-parser events file (or stdin):
A DMakefile7 build - Build ./libyaml-parser and ./libyaml-emitter
16 build: touch libyaml-parser libyaml-emitter
29 (cd $(LIBYAML_DIR) && git checkout tests/run-parser.c tests/run-emitter.c)
35 $(LIBYAML_DIR)/tests/run-parser.c \
37 $(LIBYAML_DIR)/tests/.libs/run-parser \
54 rm -fr libyaml libyaml-parser libyaml-emitter
A Dlibyaml-parser.c11 yaml_parser_t parser; in main() local
24 if (!yaml_parser_initialize(&parser)) { in main()
28 yaml_parser_set_input_file(&parser, input); in main()
32 if (!yaml_parser_parse(&parser, &event)) { in main()
33 fprintf(stderr, "Parse error: %s\n", parser.problem); in main()
116 yaml_parser_delete(&parser); in main()
/optee_benchmark/libyaml/tests/run-test-suite/
A DMakefile4 LIBYAML_DIR ?= $(PWD)/libyaml-parser-emitter/libyaml
16 test: data src/libyaml-parser
25 %/libyaml-parser %/libyaml-emitter: %
29 libyaml-parser-emitter:
A DReadMe.md4 Run libyaml-parser and libyaml-emitter against yaml-test-suite
/optee_benchmark/libyaml/tests/run-test-suite/test/
A Dlibyaml-parser.t8 ids=($(cut -d: -f1 < test/libyaml-parser.list))
16 ./src/libyaml-parser "$dir/in.yaml" > /tmp/test.out || {
/optee_benchmark/libyaml/
A D.gitignore36 /run-parser
50 /tests/run-parser
55 tests/run-test-suite/src/libyaml-parser
/optee_benchmark/libyaml/include/
A Dyaml.h1319 yaml_parser_initialize(yaml_parser_t *parser);
1328 yaml_parser_delete(yaml_parser_t *parser);
1343 yaml_parser_set_input_string(yaml_parser_t *parser,
1357 yaml_parser_set_input_file(yaml_parser_t *parser, FILE *file);
1369 yaml_parser_set_input(yaml_parser_t *parser,
1380 yaml_parser_set_encoding(yaml_parser_t *parser, yaml_encoding_t encoding);
1404 yaml_parser_scan(yaml_parser_t *parser, yaml_token_t *token);
1428 yaml_parser_parse(yaml_parser_t *parser, yaml_event_t *event);
1453 yaml_parser_load(yaml_parser_t *parser, yaml_document_t *document);
/optee_benchmark/libyaml/tests/run-test-suite/src/test/
A Dlibyaml-parser.t10 ./libyaml-parser $test > $got || rc=$?

Completed in 56 milliseconds

12